package com.lgmshare.k3;

import com.lgmshare.component.utils.FileUtils;
import com.lgmshare.component.utils.UIUtils;
import com.lgmshare.k3.manager.UserSettingManager;

/**
 * @author lim
 * @description: TODO
 * @email lgmshare@gmail.com
 * @datetime 2016/6/21 17:23
 */
public class K3Config {

    //文件存储目录
    public static final String TAG = "appName";
    public static final String FILE_DIR_LOG = "log";
    public static final String FILE_DIR_IMAGE = "image";
    public static final String FILE_DIR_DOWNLOAD = "download";
    // 每页加载数据大小
    public static final int PAGE_SIZE = 20;
    // splash加载延迟等待时间
    public static final int SPLASH_TIME_DELAY = 2000;
    // banner切换间隔时间
    public static final int SCROLL_TIME_DELAY = 5000;
    //验证码重发时间
    public static final int CODE_RETRY_TIME = 60;
    //地图定位频率
    public static final int LOCATE_SPAN_INTERVAL = 30;
    //调试模式
    public static final boolean DEBUG_MODE;
    //API接口
    public static final String INTERFACE_SITE = "k3";
    public static final String INTERFACE_VERSION = "1.0.0";
    public static final String INTERFACE_KEY = "0540476488D4850915EB2369DCFEE958";
    public static final String URL_HTTP_INTERFACE;
    public static final String URL_WEB_WEBSITE = "http://www.zsagepay.com/";
    public static final String URL_WEB_DOWNLOAD_APK = "http://h5.yixueshi.com/www/web-client2/index.html#/download";//

    //运行模式 0：开发；1：测试；2：正式
    public static final int RUNTIME_MODE = 0;

    static {
        int mode = UserSettingManager.getInstance().getRuntimeMode();
        if (mode == 0) {
            DEBUG_MODE = true;
            URL_HTTP_INTERFACE = "http://appv2.hotapi.cn/android/";
        } else if (mode == 1) {
            DEBUG_MODE = true;
            URL_HTTP_INTERFACE = "http://appv2.hotapi.cn/android/";
        } else if (mode == 2) {
            DEBUG_MODE = false;
            URL_HTTP_INTERFACE = "http://www.baidu.com/";
        } else {
            DEBUG_MODE = false;
            URL_HTTP_INTERFACE = "http://123.156.36.21/";
        }
    }
}
